package com.lanren.common.base.impl;

import com.lanren.common.base.IPresenter;
import com.lanren.common.base.IView;

/**
 * @ClassName BasePresenter
 * @Description TODO
 * @Author chongheng.wang
 * @Date 2019/9/2 13:58
 * @Version 1.0
 */
public abstract class BasePresenter<V extends IView> implements IPresenter<V> {

    //Model数据
    // protected M mModel;
    //View 显示回显的接口
    protected V mRootView;

    public BasePresenter() {
        onStart();
    }

    @Override
    public void onStart() {

    }

    @Override
    public void onDestroy() {
        this.mRootView = null;
    }

    @Override
    public void attachView(V view) {
        this.mRootView = view;
    }

    @Override
    public V getView() {
        return mRootView;
    }

}
